package com.edu.cloud.center.api;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(name = "${edu.cloud.center.regist-name}",path = "${edu.cloud.center.path}",contextId = "IEchoApi")
public interface IEchoApi {

    @GetMapping("/echo")
    public String echo(@RequestParam String str);

    @GetMapping("/echo1s")
    public String echo1s(@RequestParam String str) throws InterruptedException;

    @GetMapping("/echo2s")
    public String echo2s(@RequestParam String str) throws InterruptedException;

    @GetMapping("/echo3s")
    public String echo3s(@RequestParam String str) throws InterruptedException;

    @GetMapping("/echo2")
    public String echo2(@RequestParam("name") String str1,@RequestParam("age") String str2);

    @PostMapping("/echoPost")
    public String echoPost(@RequestParam("name") String str1,@RequestParam("age") String str2);

    @PostMapping("/echoPostPojo")
    public String echoPostPojo(@RequestBody User u);
}
